﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Xml.Serialization;

/// <summary>
/// Summary description for blti
/// </summary>
    [XmlRootAttribute("cartridge_basiclti_link", Namespace = "http://www.imsglobal.org/xsd/imslticc_v1p0", IsNullable = false)]
    public class Blti
    {
        [XmlRootAttribute("property", Namespace = "http://www.imsglobal.org/xsd/imslticm_v1p0")]
        public class CustomProperty
        {
            [XmlAttribute("name", Namespace = "http://www.imsglobal.org/xsd/imslticm_v1p0")]
            public string Name;

            [XmlText]
            public string Value;
        }

        [XmlRootAttribute("vendor", Namespace = "http://www.imsglobal.org/xsd/imslticc_v1p0")]
        public class VendorProperty
        {
            [XmlElement("code", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public string Code;

            [XmlElement("name", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public string Name;

            [XmlElement("description", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public string Description;

            [XmlElement("url", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public string Url;

            [XmlElement("contact", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public ContactProperty Contact;

            //[XmlRootAttribute("Contact", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
            public class ContactProperty
            {
                [XmlElement("email", Namespace = "http://www.imsglobal.org/xsd/imslticp_v1p0")]
                public string Email;
            }
        }

        [XmlElement("title", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string Title;

        [XmlElement("description", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string Description;

        [XmlArray("custom", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0"), XmlArrayItem("property", Namespace = "http://www.imsglobal.org/xsd/imslticm_v1p0")]
        public CustomProperty[] Custom;

        [XmlArray("extensions", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0"), XmlArrayItem("property", Namespace = "http://www.imsglobal.org/xsd/imslticm_v1p0")]
        public CustomProperty[] Extensions;

        [XmlElement("launch_url", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string LaunchUrl;

        [XmlElement("secure_lauch_url", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string SecureLaunchUrl;

        [XmlElement("icon", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string Icon;

        [XmlElement("secure_icon", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public string SecureIcon;

        [XmlElement("vendor", Namespace = "http://www.imsglobal.org/xsd/imsbasiclti_v1p0")]
        public VendorProperty Vendor;
}
